﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Admin_ProList.aspx.cs" Inherits="admin_Admin_ProList" %>

<%@ Register Src="../Controls/AdminCheck.ascx" TagName="AdminCheck" TagPrefix="uc1" %>
<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>无标题页</title>
        <link href="Images/css1/css.css" rel="stylesheet" type="text/css">
</head>
<SCRIPT language=javascript>
<!--
var displayBar=true;
function switchBar(obj){
	if (displayBar)
	{
		parent.frame.cols="0,*";
		displayBar=false;
		obj.value="打开左边管理菜单";
	}
	else{
		parent.frame.cols="195,*";
		displayBar=true;
		obj.value="关闭左边管理菜单";
	}
}


//-->
</SCRIPT>
<body>
    <form id="form1" runat="server">
<table class="table" cellspacing="1" cellpadding="2" width="auto" align="center" border="0">
  <tbody>
    <tr>
      <th class="bg_tr" align="left" colspan="4" height="25"> <span style="font-size:18px;">产品系统</span>   
      <input onClick="switchBar(this)" type="button" value="关闭左边管理菜单" name="SubmitBtn" />&nbsp;
          <asp:Button ID="Button3" runat="server" onclick="Button3_Click" 
              Text="重新生成所有商品静态页面" Width="168px" />
                </th>
    </tr>
    <tr>
      <td class="td_bg" colspan="4">    
      <asp:GridView ID="ProList" runat="server"  AutoGenerateColumns="False" 
              OnRowDataBound="ProList_RowDataBound" HorizontalAlign="Center" 
              OnRowDeleting="ProList_RowDeleting" 
               EnableModelValidation="True">
                        <Columns>
                           <asp:TemplateField HeaderText="删除"  HeaderStyle-Width="40" ItemStyle-HorizontalAlign="Center" >
                                <ItemTemplate>
                                    <asp:CheckBox ID="del" runat="server" />
                                </ItemTemplate>

<HeaderStyle Width="40px"></HeaderStyle>

<ItemStyle HorizontalAlign="Center"></ItemStyle>
                           </asp:TemplateField>
                           <asp:BoundField DataField="Ptypeid" HeaderText="所属类别" ReadOnly="true" 
                                HeaderStyle-Width="80" ItemStyle-Width="80" 
                                ItemStyle-HorizontalAlign="Center" > 
<HeaderStyle Width="80px"></HeaderStyle>

<ItemStyle HorizontalAlign="Center" Width="80px"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="Pname" HeaderText="产品名" ReadOnly="true" 
                                HeaderStyle-Width="300" ItemStyle-Width="200" > 
<HeaderStyle Width="200px"></HeaderStyle>

<ItemStyle Width="200px"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="Pkey" HeaderText="关键字"  
                                 HeaderStyle-Width="200" >
<HeaderStyle Width="200"></HeaderStyle>

<ItemStyle ></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="HtmlUrl" HeaderText="页面地址" 
                               HeaderStyle-Width="200" >
<HeaderStyle Width="200px"></HeaderStyle>

<ItemStyle ></ItemStyle>
                            </asp:BoundField>
                                                        <asp:BoundField DataField="Psort" HeaderText="排序" 
                                ItemStyle-HorizontalAlign="Center" HeaderStyle-Width="50" >
<HeaderStyle Width="50"></HeaderStyle>

<ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:TemplateField HeaderText="添加时间"  HeaderStyle-Width="80" ItemStyle-HorizontalAlign="Center" >
                                <ItemTemplate>
                                    <asp:Literal ID="Literal1" runat="server" Text='<%# Eval("Ptime","{0:yyyy-M-dd}") %>'></asp:Literal>
                                </ItemTemplate>

<HeaderStyle Width="80px"></HeaderStyle>

<ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:TemplateField>
                            <asp:CommandField HeaderText="删除" ShowDeleteButton="True" 
                                HeaderStyle-Width="40" ItemStyle-HorizontalAlign="Center" >
<HeaderStyle Width="40px"></HeaderStyle>

<ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:CommandField>
                            <asp:HyperLinkField HeaderText="详细" Text="详细" 
                                DataNavigateUrlFormatString="~/admin/Admin_ProUpdate.aspx?id={0}" 
                                DataNavigateUrlFields="Pid"  HeaderStyle-Width="40" 
                                ItemStyle-HorizontalAlign="Center" >
<HeaderStyle Width="40px"></HeaderStyle>

<ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:HyperLinkField>
                        </Columns>
                        <HeaderStyle BackColor="#E4F1FA" Font-Bold="True" ForeColor="#006699" />
                       </asp:GridView></td>
    </tr>
        <tr> 
      <td class="bg_tr" align="left" colspan="4" height="26">
      <div style="float:left;"> <asp:Button ID="Button2" runat="server" Text="全选" OnClick="Button2_Click"   CssClass="input_1" />
      <asp:Button ID="Button1" runat="server" Text="删除" OnClick="Button1_Click"  CssClass="input_1" /></div>
      <webdiyer:AspNetPager ID="AspNetPager1" runat="server" pagesize="15"  CssClass="paginator"
         onpagechanged="AspNetPager1_PageChanged" 
         CurrentPageButtonPosition="Center" 
         CustomInfoHTML="第%CurrentPageIndex%页，共%PageCount%页，每页显示%PageSize%条信息" 
         FirstPageText="首页" LastPageText="尾页" LayoutType="div" NextPageText="下一页" 
         PageIndexBoxType="textbox" PagingButtonLayoutType="Span" 
         PrevPageText="上一页" ShowCustomInfoSection="Left" SubmitButtonText="Go" 
         ShowPageIndexBox="Always"  TextBeforePageIndexBox="转到第" TextAfterPageIndexBox="页" >
     </webdiyer:AspNetPager>

    </td>
    </tr>
  </tbody>
</table>
        <uc1:AdminCheck ID="AdminCheck1" runat="server" />
    </form>
</body>
</html>
